package com.shadowtorcher.stdisk.bean;

import com.shadowtorcher.soulknife.DataSupport;
import com.shadowtorcher.soulknife.exception.BeanConfigErrorException;
import com.shadowtorcher.stdisk.util.StaticUtils;

import java.sql.SQLException;

public class PermissionBean extends DataSupport {
    private String PermissionID; // 主键
    private String Permissions;

    @Override
    public void save() throws BeanConfigErrorException, SQLException {
        if (this.PermissionID == null) {
            this.PermissionID = StaticUtils.generatorStringUUID();
        }
        super.save();
    }

    public String getPermissionID() {
        return PermissionID;
    }

    public void setPermissionID(String permissionID) {
        PermissionID = permissionID;
    }

    public String getPermissions() {
        return Permissions;
    }

    public void setPermissions(String permissions) {
        Permissions = permissions;
    }
}
